# Maintainer(Arch): Jelle van der Waa <jelle@vdwaa.nl>
# Maintainer: Sagar Acharya <sagar@hyperbola.info>

pkgbase=python-webencodings
pkgname='python-webencodings'
pkgver=0.5.1
pkgrel=6
arch=('any')
url="https://github.com/gsnedders/python-webencodings"
license=('Modified-BSD')
makedepends=('python' 'python-setuptools')
checkdepends=('python-nose')
source=(https://github.com/gsnedders/python-webencodings/archive/v${pkgver}.tar.gz)
sha512sums=('c5cb34f35fb5bc7ffb88c19eb3262dedbf6231c0ee2871dccbc0f9497193d8209fc20703d451a2bb41a5ff913e63abf7481f7a8f9886c953724e9cf71c34cb74')

package_python-webencodings() {
pkgdesc="This is a Python implementation of the WHATWG Encoding standard."
depends=('python')
    cd ${pkgbase}-${pkgver}

    python3 setup.py install --root="${pkgdir}"
    install -D -m644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}

check() {
    cd ${pkgbase}-${pkgver}/webencodings
    nosetests tests.py
}
